home *** CD-ROM | disk | FTP | other *** search
/ Sounds Terrific 1 / Sounds Terrific CD (1994)(Weird Science)(Disc 2 of 2)[!][Amiga-PC].iso / modules / l / logons.mod < prev    next >
Encoding:
Text File  |  1994-08-04  |  2.5 KB  |  84 lines

  1. LOGONS.MOD : Fix the Logons Search Pattern in UEDIT.C
  2. Aaron Thicke #1 @8775
  3. Sun Dec 08 01:23:47 1991
  4. NAME: LOGONS.MOD
  5. DATE: 12-09-91
  6. VER:  4.2B (as far as I know)
  7. FILES: UEDIT.C
  8. PROBLEM: When you do a search in the User Editor, and you choose to search
  9.          for say, LOGONS<[2], the computer would do nothing. Well, here is 
  10.          the Fix.
  11.  
  12. /***************************************************************************/
  13.  
  14.  
  15. In UEDIT.C, search for the code..........
  16.  
  17.  
  18.  
  19.  
  20.           } else if (!strcmp(fcn,"LASTON")) {
  21.             time(&l);
  22.             tmp2=(unsigned int)( (l-u->daten)/24.0/3600.0 );
  23.             if (less)
  24.               tmp=tmp2<tmp1;
  25.             else
  26.               tmp=tmp2>tmp1;
  27.           } else if (!strcmp(fcn,"AREACODE")) {
  28.             tmp=(!strncmp(parm,u->phone,3));
  29.           } else if (!strcmp(fcn,"RESTRICT")) {
  30.             ;
  31.           } else if (!strcmp(fcn,"LOGONS")) {
  32.             if (less)
  33.               tmp=thisuser.logons<tmp1;
  34.             else
  35.               tmp=thisuser.logons>tmp1;
  36.           }
  37.  
  38.         } else
  39.           tmp=match_user(u);
  40.  
  41. Make the above code look like the code below. The way that WWIV was looking
  42. for the specified logons was incorrect. Reflect the changes below....
  43.  
  44.  
  45. /**************************************************************************/
  46.  
  47.           } else if (!strcmp(fcn,"LASTON")) {
  48.             time(&l);
  49.             tmp2=(unsigned int)( (l-u->daten)/24.0/3600.0 );
  50.             if (less)
  51.               tmp=tmp2<tmp1;
  52.             else
  53.               tmp=tmp2>tmp1;
  54.           } else if (!strcmp(fcn,"AREACODE")) {
  55.             tmp=(!strncmp(parm,u->phone,3));
  56.           } else if (!strcmp(fcn,"RESTRICT")) {
  57.             ;
  58.           } else if (!strcmp(fcn,"LOGONS")) {
  59.             if (less)
  60.               tmp=(tmp1>u->logons);         /* Change */
  61.             else
  62.               tmp=(tmp1<u->logons);         /* Change */
  63.           }
  64.  
  65.         } else
  66.           tmp=match_user(u);
  67. /**************************************************************************/
  68.  
  69. Thats it. Now, when you do a Search for 
  70.  
  71. LOGONS<[2]
  72.  
  73. The computer will now do what it should, instead of doing nothing.
  74.  
  75. If you have any questions, just let me know. L8r, Aaron.
  76.  
  77.  
  78.  
  79.                                 The Beef House
  80.                           An Alternative Lifestyles BBS
  81.                         One In Ten Is Still The Average!! 
  82.                       Metro 817-267-1039 | 2400 | WWIV 4.20
  83.  
  84.